CMSC 425 : Lecture 4 More about OpenGL and GLUT
نویسنده
چکیده
Idealized Drawing Window: Because we generally do not have complete control over the window size, it is a good idea to think in terms of drawing on a rectangular idealized drawing region, whose size and shape are completely under our control. Then we will scale this region to fit within the actual graphics window on the display. There are many reasons for doing this. For example, if you design your program to work specifically for 400 × 400 window, but then the user resizes the window, what do you do? It is a much better idea to assume a window of arbitrary size. For example, you could define two variables w and h, that indicate the width and height of the window, respectively. The values w and h could be measured in whatever units are most natural to your application: pixels, inches, light years, microns, furlongs or fathoms.
منابع مشابه
CMSC 425 Dave Mount CMSC 425 : Lecture 6 3 - d Viewing and Projections
Viewing in OpenGL: Today we will discuss how viewing and perspective transformations are handled for 3-dimensional scenes. In OpenGL, and most similar graphics systems, the process involves the following basic steps, of which the perspective transformation is just one component. We assume that all objects are initially represented relative to a standard 3-dimensional coordinate frame, in what a...
متن کاملCMSC 425 Dave Mount CMSC 425 : Lecture 5 Drawing in OpenGL : Transformations Thursday
Complex Drawing in OpenGL: So far we have discussed how to draw simple 2-dimensional objects using OpenGL. Suppose that we want to draw more complex scenes. For example, we want to draw objects that move and rotate or to change the projection. We could do this by computing (ourselves) the coordinates of the transformed vertices. However, this would be inconvenient for us. It would also be ineff...
متن کاملCMSC 425 Dave Mount CMSC 425 : Lecture 4 Geometry and Geometric Programming
Such basic geometric problems are fundamental to computer graphics, and over the next few lectures, our goal will be to present the tools needed to answer these sorts of questions. (By the way, a good source of information on how to solve these problems is the series of books entitled “Graphics Gems”. Each book is a collection of many simple graphics problems and provides algorithms for solving...
متن کاملCMSC 425 Dave Mount CMSC 425 : Lecture 3 Introduction to Unity
Unity: Unity is a widely-used cross-platform game develop system. It consists of a game engine and an integrated development environment (IDE). It can be used to develop games for many different platforms, including PCs, consoles, mobile devices, and deployment on the Web. In this lecture, we will present the basic elements of Unity. However, this is a complex system, and we will not have time ...
متن کاملCMSC 425 Game Programming
1 Copyright, David M. Mount, 2016, Dept. of Computer Science, University of Maryland, College Park, MD, 20742. These lecture notes were prepared by David Mount for the course CMSC 425, Game Programming, at the University of Maryland. Permission to use, copy, modify, and distribute these notes for educational purposes and without fee is hereby granted, provided that this copyright notice appear ...
متن کامل